<?php
// 中间件配置
return [
    // 别名或分组
    'alias'    => [
        // 定义中间件别名标识
        'auth'	=>	app\middleware\Authenticate::class,
        'adminAuth' => app\middleware\AdminAuthenticate::class,
        'localization' => app\middleware\Localization::class,
        'cors' => app\middleware\CorsMiddleware::class,

        // 定义一组中间件
        'web' => [
            app\middleware\EncryptCookies::class,
            app\middleware\VerifyCsrfToken::class,
            app\middleware\Initialize::class,
            app\middleware\AfterMiddleware::class,
        ],
    ],
    // 优先级设置，此数组中的中间件会按照数组中的顺序优先执行
    'priority' => [
        //think\middleware\SessionInit::class,
    ],
];
